enum ESB_VerticalAlignment
{
	ESB_ALIGN_CENTER_VERTICAL,
	ESB_ALIGN_TOP,
	ESB_ALIGN_BOTTOM,
	ESB_EXACT_FIT_VERTICAL
};
enum ESB_HorizontalAlignment
{
	ESB_ALIGN_CENTER_HORIZONTAL,
	ESB_ALIGN_LEFT,
	ESB_ALIGN_RIGHT,
	ESB_EXACT_FIT_HORIZONTAL
};
class EnhancedStatusBarItem
{
public:
	EnhancedStatusBarItem(wxWindow *pWidget, int pPos, ESB_HorizontalAlignment pha = ESB_ALIGN_CENTER_HORIZONTAL, ESB_VerticalAlignment pva = ESB_ALIGN_CENTER_VERTICAL);
	wxWindow *widget;
	int pos;
	ESB_HorizontalAlignment horizontalAlignment;
	ESB_VerticalAlignment verticalAlignment;
};
class EnhancedStatusBar : public wxStatusBar
{
public:
	EnhancedStatusBar(wxWindow *parent, wxWindowID id = wxID_ANY, long style = wxST_SIZEGRIP,const  wxString &name = "EnhancedStatusBar");
	~EnhancedStatusBar();
	bool AddWidget(wxWindow *widget, ESB_HorizontalAlignment horizontalAlignment = ESB_ALIGN_CENTER_HORIZONTAL, ESB_VerticalAlignment verticalAlignment = ESB_ALIGN_CENTER_VERTICAL, int pos = -1);
private:
	void OnSize(wxSizeEvent &event);
	void DoSize();
	vector<EnhancedStatusBarItem *> items;
	int curPos;
	wxWindow *parent;
};